package com.my.createtype.singletion;

public class Singleton {

	public static class Holder {
		private static Singleton s = new Singleton();
		
		public Holder() {
			System.out.println("Singleton.Holder.Holer()");
		}
	}
	
/*	public static class Holder {
		private static Singleton s = new Singleton();
		
		public Holder() {
			System.out.println("Singleton.Holder.Holer()");
		}
	}
*/	
	public static Singleton getInstance() {
		return Holder.s;
	}
	
	private Singleton() {
		System.out.println("Singleton.Singleton()");
	}

}
